/**
 * @author: Niimp
 * @date: 2023/12/1 14:02
 * @statement:
 */
package cn.kgc.controller;

import com.alibaba.fastjson.JSONObject;
import com.dz.config.result.HttpStatusEnum;
import com.dz.config.result.ResponseResult;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.client.RestTemplate;

import javax.annotation.Resource;
import java.util.List;

@Api(tags = "监测管理")
@RestController
@RequestMapping("/monitoringManagement")
public class MonitoringManagementController {

    @Resource
    private RestTemplate restTemplate;

    private final String PAYMENTURL = "http://localhost:8002/monitoringManagement/";

    @ApiOperation(value = "监测点信息查询")
    @PostMapping("/queryMonitorInfo")
    @ResponseBody
    @ApiImplicitParams({
            @ApiImplicitParam(name = "cityCode", value = "市编号", required = true, defaultValue = "430900", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "countyCode", value = "县编号", required = false, defaultValue = "", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "monitoringCode", value = "监测点编号", required = false, defaultValue = "admin", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "monitoringName", value = "监测点名称", required = false, defaultValue = "admin", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "disasterType", value = "灾害类型", required = false, defaultValue = "admin", dataType = "String", paramType = "query"),
    })
    public ResponseResult queryMonitorInfo(@RequestBody JSONObject jsonObject) {
        return restTemplate.postForObject(PAYMENTURL + "queryMonitorInfo", jsonObject,ResponseResult.class);
    }



    @ApiOperation(value = "监测点传感器查询")
    @PostMapping("/queryMonitorAndSensorInfo")
    @ResponseBody
    @ApiImplicitParams({
            @ApiImplicitParam(name = "currentPage", value = "当前页", required = true, defaultValue = "01", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "pageSize", value = "页面大小", required = true, defaultValue = "10", dataType = "String", paramType = "query"),
    })
    public ResponseResult queryMonitorAndSensorInfo(@RequestBody JSONObject jsonObject) {
        return restTemplate.postForObject(PAYMENTURL + "queryMonitorAndSensorInfo", jsonObject,ResponseResult.class);
    }



    @ApiOperation(value = "报警信息查询")
    @PostMapping("/queryMonitorWaringInfo")
    @ResponseBody
    @ApiImplicitParams({
            @ApiImplicitParam(name = "dateTime", value = "时间", required = true, defaultValue = "2023-11-09 17:45:19", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "startTime", value = "开始时间", required = false, defaultValue = "2023-11-09 19:01:01.698", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "endTime", value = "结束时间", required = false, defaultValue = "2023-11-10 20:31:55.759", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "waringLevel", value = "预警等级(1：红，2：橙、3：黄、4：蓝)", required = false, defaultValue = "", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "waringStatus", value = "预警状态1:有 0:无", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "dateLevel", value = "日期等级(日、周、月、年)", required = false, defaultValue = "日", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "jcdId", value = "监测点编号", required = true,  dataType = "String", paramType = "query"),

    })
    public ResponseResult queryMonitorWaringInfo(@RequestBody JSONObject jsonObject) {
        return restTemplate.postForObject(PAYMENTURL + "queryMonitorWaringInfo", jsonObject,ResponseResult.class);
    }


    @ApiOperation(value = "监测曲线-地表位移")
    @PostMapping("/queryDetectionCurveSurfaceDisplacement")
    @ResponseBody
    @ApiImplicitParams({
            @ApiImplicitParam(name = "dateTime", value = "时间", required = false, defaultValue = "2023-12-05 09:32:00", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "startTime", value = "开始时间", required = false, defaultValue = "2023-12-05 08:00:00", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "endTime", value = "结束时间", required = false, defaultValue = "2023-12-06 09:36:09", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "dateLevel", value = "日期等级(1日、3日、7日、15日、30日)", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "countLevel", value = "实时:任意 小时:2 天:3 月:4", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "monitorCode", value = "监测点编码", required = false, defaultValue = "431123011160", dataType = "String", paramType = "query")
    })
    public ResponseResult queryDetectionCurveSurfaceDisplacement(@RequestBody JSONObject jsonObject) {
        return restTemplate.postForObject(PAYMENTURL + "queryDetectionCurveSurfaceDisplacement", jsonObject,ResponseResult.class);
    }


    @ApiOperation(value = "监测曲线-加速度")
    @PostMapping("/queryDetectionCurveAcceleration")
    @ResponseBody
    @ApiImplicitParams({
            @ApiImplicitParam(name = "dateTime", value = "时间", required = false, defaultValue = "2023-12-05 12:00:01", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "startTime", value = "开始时间", required = false, defaultValue = "2023-12-05 12:00:01", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "endTime", value = "结束时间", required = false, defaultValue = "2023-12-06 14:53:14", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "dateLevel", value = "日期等级(1日、3日、7日、15日、30日)", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "countLevel", value = "实时:任意 小时:2 天:3 月:4", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "monitorCode", value = "监测点编码", required = false, defaultValue = "430725021159", dataType = "String", paramType = "query")

    })
    public ResponseResult queryDetectionCurveAcceleration(@RequestBody JSONObject jsonObject) {
        return restTemplate.postForObject(PAYMENTURL + "queryDetectionCurveAcceleration", jsonObject,ResponseResult.class);
    }


    @ApiOperation(value = "监测曲线-倾角")
    @PostMapping("/queryDetectionCurveDipAngle")
    @ResponseBody
    @ApiImplicitParams({
            @ApiImplicitParam(name = "dateTime", value = "时间", required = false, defaultValue = "2023-12-05 14:00:01", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "startTime", value = "开始时间", required = false, defaultValue = "2023-12-05 00:00:02", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "endTime", value = "结束时间", required = false, defaultValue = "2023-12-06 11:00:02", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "dateLevel", value = "日期等级(1日、3日、7日、15日、30日)", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "countLevel", value = "实时:任意 小时:2 天:3 月:4", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "monitorCode", value = "监测点编码", required = false, defaultValue = "430581011262", dataType = "String", paramType = "query")

    })
    public ResponseResult queryDetectionCurveDipAngle(@RequestBody JSONObject jsonObject) {
        return restTemplate.postForObject(PAYMENTURL + "queryDetectionCurveDipAngle", jsonObject,ResponseResult.class);
    }

    @ApiOperation(value = "监测曲线-雨量")
    @PostMapping("/queryDetectionCurveRainfall")
    @ResponseBody
    @ApiImplicitParams({
            @ApiImplicitParam(name = "dateTime", value = "时间", required = false, defaultValue = "2023-12-05 14:00:01", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "startTime", value = "开始时间", required = false, defaultValue = "2023-12-06 12:00:02", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "endTime", value = "结束时间", required = false, defaultValue = "2023-12-09 18:00:02", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "dateLevel", value = "日期等级(1日、3日、7日、15日、30日)", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "countLevel", value = "实时:任意 小时:2 天:3 月:4", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "monitorCode", value = "监测点编码", required = false, defaultValue = "431322001397", dataType = "String", paramType = "query")

    })
    public ResponseResult queryDetectionCurveRainfall(@RequestBody JSONObject jsonObject) {
        return restTemplate.postForObject(PAYMENTURL + "queryDetectionCurveRainfall", jsonObject,ResponseResult.class);
    }


    @ApiOperation(value = "监测曲线-气温")
    @PostMapping("/queryDetectionCurveAirTemperature")
    @ResponseBody
    @ApiImplicitParams({
            @ApiImplicitParam(name = "dateTime", value = "时间", required = false, defaultValue = "2023-12-05 14:00:01", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "startTime", value = "开始时间", required = false, defaultValue = "2023-12-05 12:00:01", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "endTime", value = "结束时间", required = false, defaultValue = "2023-12-05 14:53:14", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "dateLevel", value = "日期等级(1日、3日、7日、15日、30日)", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "countLevel", value = "实时:任意 小时:2 天:3 月:4", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "monitorCode", value = "监测点编码", required = false, defaultValue = "431322001397", dataType = "String", paramType = "query")

    })
    public ResponseResult queryDetectionCurveAirTemperature(@RequestBody JSONObject jsonObject) {
        return restTemplate.postForObject(PAYMENTURL + "queryDetectionCurveAirTemperature", jsonObject,ResponseResult.class);
    }

    @ApiOperation(value = "监测曲线-裂缝")
    @PostMapping("/queryDetectionCurveCrack")
    @ResponseBody
    @ApiImplicitParams({
            @ApiImplicitParam(name = "dateTime", value = "时间", required = false, defaultValue = "2023-12-05 14:00:01", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "startTime", value = "开始时间", required = false, defaultValue = "2023-12-05 12:00:01", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "endTime", value = "结束时间", required = false, defaultValue = "2023-12-05 14:53:14", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "dateLevel", value = "日期等级(1日、3日、7日、15日、30日)", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "countLevel", value = "实时:任意 小时:2 天:3 月:4", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "monitorCode", value = "监测点编码", required = false, defaultValue = "430382031094", dataType = "String", paramType = "query")

    })
    public ResponseResult queryDetectionCurveCrack(@RequestBody JSONObject jsonObject) {
        return restTemplate.postForObject(PAYMENTURL + "queryDetectionCurveCrack", jsonObject,ResponseResult.class);
    }


    @ApiOperation(value = "监测曲线- 土壤含水率")
    @PostMapping("/queryDetectionCurveSoilMoistureContent")
    @ResponseBody
    @ApiImplicitParams({
            @ApiImplicitParam(name = "dateTime", value = "时间", required = false, defaultValue = "2023-12-05 14:00:01", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "startTime", value = "开始时间", required = false, defaultValue = "2023-12-05 12:00:01", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "endTime", value = "结束时间", required = false, defaultValue = "2023-12-05 14:53:14", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "dateLevel", value = "日期等级(1日、3日、7日、15日、30日)", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "countLevel", value = "实时:任意 小时:2 天:3 月:4", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "monitorCode", value = "监测点编码", required = false, defaultValue = "430382031094", dataType = "String", paramType = "query")

    })
    public ResponseResult queryDetectionCurveSoilMoistureContent(@RequestBody JSONObject jsonObject) {
        return restTemplate.postForObject(PAYMENTURL + "queryDetectionCurveSoilMoistureContent", jsonObject,ResponseResult.class);
    }


    @ApiOperation(value = "监测曲线- 泥水位")
    @PostMapping("/queryDetectionCurveMudWaterLevel")
    @ResponseBody
    @ApiImplicitParams({
            @ApiImplicitParam(name = "dateTime", value = "时间", required = false, defaultValue = "2023-12-05 14:00:01", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "startTime", value = "开始时间", required = false, defaultValue = "2023-12-05 12:00:01", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "endTime", value = "结束时间", required = false, defaultValue = "2023-12-05 14:53:14", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "dateLevel", value = "日期等级(1日、3日、7日、15日、30日)", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "countLevel", value = "实时:任意 小时:2 天:3 月:4", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "monitorCode", value = "监测点编码", required = false, defaultValue = "430382031094", dataType = "String", paramType = "query")

    })
    public ResponseResult queryDetectionCurveMudWaterLevel(@RequestBody JSONObject jsonObject) {
        return restTemplate.postForObject(PAYMENTURL + "queryDetectionCurveMudWaterLevel", jsonObject,ResponseResult.class);
    }



    @ApiOperation(value = "监测曲线- 气压")
    @PostMapping("/queryDetectionCurvePressure")
    @ResponseBody
    @ApiImplicitParams({
            @ApiImplicitParam(name = "dateTime", value = "时间", required = false, defaultValue = "2023-12-05 14:00:01", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "startTime", value = "开始时间", required = false, defaultValue = "2021-10-30 07:00:00", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "endTime", value = "结束时间", required = false, defaultValue = "2021-10-31 22:00:00", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "dateLevel", value = "日期等级(1日、3日、7日、15日、30日)", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "countLevel", value = "实时:任意 小时:2 天:3 月:4", required = false, defaultValue = "430923001298", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "monitorCode", value = "监测点编码", required = false, defaultValue = "1", dataType = "String", paramType = "query")

    })
    public ResponseResult queryDetectionCurvePressure(@RequestBody JSONObject jsonObject) {
        return restTemplate.postForObject(PAYMENTURL + "queryDetectionCurvePressure", jsonObject,ResponseResult.class);
    }


    @ApiOperation(value = "监测曲线- 振动")
    @PostMapping("/queryDetectionCurveVibrate")
    @ResponseBody
    @ApiImplicitParams({
            @ApiImplicitParam(name = "dateTime", value = "时间", required = false, defaultValue = "2023-12-05 14:00:01", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "startTime", value = "开始时间", required = false, defaultValue = "2021-07-02 00:00:49", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "endTime", value = "结束时间", required = false, defaultValue = "2021-07-02 23:50:55", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "dateLevel", value = "日期等级(1日、3日、7日、15日、30日)", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "countLevel", value = "实时:任意 小时:2 天:3 月:4", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "monitorCode", value = "监测点编码", required = false, defaultValue = "430923011065", dataType = "String", paramType = "query")

    })
    public ResponseResult queryDetectionCurveVibrate(@RequestBody JSONObject jsonObject) {
        return restTemplate.postForObject(PAYMENTURL + "queryDetectionCurveVibrate", jsonObject,ResponseResult.class);
    }


    @ApiOperation(value = "监测曲线- 深度位移")
    @PostMapping("/queryDetectionCurveDeepDisplacement")
    @ResponseBody
    @ApiImplicitParams({
            @ApiImplicitParam(name = "dateTime", value = "时间", required = false, defaultValue = "2023-12-05 14:00:01", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "startTime", value = "开始时间", required = false, defaultValue = "2023-12-07 12:00:02", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "endTime", value = "结束时间", required = false, defaultValue = "2023-12-09 18:00:02", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "dateLevel", value = "日期等级(1日、3日、7日、15日、30日)", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "countLevel", value = "实时:任意 小时:2 天:3 月:4", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "monitorCode", value = "监测点编码", required = false, defaultValue = "431382040035", dataType = "String", paramType = "query")

    })
    public ResponseResult queryDetectionCurveDeepDisplacement(@RequestBody JSONObject jsonObject) {
        return restTemplate.postForObject(PAYMENTURL + "queryDetectionCurveDeepDisplacement", jsonObject,ResponseResult.class);
    }


    @ApiOperation(value = "监测曲线- 土压力")
    @PostMapping("/queryDetectionCurveSoilPressure")
    @ResponseBody
    @ApiImplicitParams({
            @ApiImplicitParam(name = "dateTime", value = "时间", required = false, defaultValue = "2023-12-05 14:00:01", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "startTime", value = "开始时间", required = false, defaultValue = "2023-12-07 12:00:02", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "endTime", value = "结束时间", required = false, defaultValue = "2023-12-09 18:00:02", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "dateLevel", value = "日期等级(1日、3日、7日、15日、30日)", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "countLevel", value = "实时:任意 小时:2 天:3 月:4", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "monitorCode", value = "监测点编码", required = false, defaultValue = "430321011127", dataType = "String", paramType = "query")

    })
    public ResponseResult queryDetectionCurveSoilPressure(@RequestBody JSONObject jsonObject) {
        return restTemplate.postForObject(PAYMENTURL + "queryDetectionCurveSoilPressure", jsonObject,ResponseResult.class);
    }


    @ApiOperation(value = "监测曲线- 土壤温度")
    @PostMapping("/queryDetectionCurveSoilTempera")
    @ResponseBody
    @ApiImplicitParams({
            @ApiImplicitParam(name = "dateTime", value = "时间", required = false, defaultValue = "2023-12-05 14:00:01", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "startTime", value = "开始时间", required = false, defaultValue = "2023-12-07 12:00:02", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "endTime", value = "结束时间", required = false, defaultValue = "2023-12-09 18:00:02", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "dateLevel", value = "日期等级(1日、3日、7日、15日、30日)", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "countLevel", value = "实时:任意 小时:2 天:3 月:4", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "monitorCode", value = "监测点编码", required = false, defaultValue = "430725011030", dataType = "String", paramType = "query")

    })
    public ResponseResult queryDetectionCurveSoilTempera(@RequestBody JSONObject jsonObject) {
        return restTemplate.postForObject(PAYMENTURL + "queryDetectionCurveSoilTempera", jsonObject,ResponseResult.class);
    }

    @ApiOperation(value = "监测曲线- 地下水位水温")
    @PostMapping("/queryDetectionCurveUndergroundWaterLevelTempera")
    @ResponseBody
    @ApiImplicitParams({
            @ApiImplicitParam(name = "dateTime", value = "时间", required = false, defaultValue = "2023-12-05 14:00:01", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "startTime", value = "开始时间", required = false, defaultValue = "2023-12-07 12:00:02", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "endTime", value = "结束时间", required = false, defaultValue = "2023-12-09 18:00:02", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "dateLevel", value = "日期等级(1日、3日、7日、15日、30日)", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "countLevel", value = "实时:任意 小时:2 天:3 月:4", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "monitorCode", value = "监测点编码", required = false, defaultValue = "430923019013", dataType = "String", paramType = "query")

    })
    public ResponseResult queryDetectionCurveUndergroundWaterLevelTempera(@RequestBody JSONObject jsonObject) {
        return restTemplate.postForObject(PAYMENTURL + "queryDetectionCurveUndergroundWaterLevelTempera", jsonObject,ResponseResult.class);
    }


    @ApiOperation(value = "监测曲线- 孔隙水压力监测")
    @PostMapping("/queryDetectionCurvePoreWaterPressure")
    @ResponseBody
    @ApiImplicitParams({
            @ApiImplicitParam(name = "dateTime", value = "时间", required = false, defaultValue = "2023-12-05 14:00:01", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "startTime", value = "开始时间", required = false, defaultValue = "2023-12-07 12:00:02", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "endTime", value = "结束时间", required = false, defaultValue = "2023-12-09 18:00:02", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "dateLevel", value = "日期等级(1日、3日、7日、15日、30日)", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "countLevel", value = "实时:任意 小时:2 天:3 月:4", required = false, defaultValue = "1", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "monitorCode", value = "监测点编码", required = false, defaultValue = "430822011119", dataType = "String", paramType = "query")

    })
    public ResponseResult queryDetectionCurvePoreWaterPressure(@RequestBody JSONObject jsonObject) {
        return restTemplate.postForObject(PAYMENTURL + "queryDetectionCurvePoreWaterPressure", jsonObject,ResponseResult.class);
    }


    @ApiOperation(value = "预警模型")
    @PostMapping("/queryWaringModel")
    @ResponseBody
    @ApiImplicitParams({
            @ApiImplicitParam(name = "singleOrMultipleParameters", value = "单参数or多参数 0/1", required = false, defaultValue = "0", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "warningFrequency", value = "预警频率", required = false, defaultValue = "24", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "monitorCode", value = "监测点编码", required = false, defaultValue = "431102010230", dataType = "String", paramType = "query")

    })
    public ResponseResult queryWaringModel(@RequestBody JSONObject jsonObject) {
        return restTemplate.postForObject(PAYMENTURL + "queryWaringModel", jsonObject,ResponseResult.class);
    }


    @ApiOperation(value = "表达式更新")
    @PostMapping("/updateExpression")
    @ResponseBody
    @ApiImplicitParams({
            @ApiImplicitParam(name = "monitorCode", value = "监测点编码", required = true, defaultValue = "433130039002", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "monitorExpression", value = "表达式", required = true,
                    defaultValue = "4331300390020301YL01(雨量)蓝色预警 且 ( 4331300390020201NW01(泥水位)蓝色预警 )", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "waringType", value = "预警类型蓝4黄3橙2红1", required = false, defaultValue = "4", dataType = "String", paramType = "query"),
    })
    public ResponseResult updateExpression(@RequestBody JSONObject jsonObject) {
        return restTemplate.postForObject(PAYMENTURL + "updateExpression", jsonObject,ResponseResult.class);
    }



    @ApiOperation(value = "表达式删除")
    @PostMapping("/deleteExpression")
    @ResponseBody
    @ApiImplicitParams({
            @ApiImplicitParam(name = "monitorCode", value = "监测点编码", required = true, defaultValue = "433130039002", dataType = "String", paramType = "query"),
            @ApiImplicitParam(name = "waringType", value = "预警类型蓝4黄3橙2红1", required = false, defaultValue = "4", dataType = "String", paramType = "query"),
    })
    public ResponseResult deleteCriterionDelete(@RequestBody JSONObject jsonObject) {
        return restTemplate.postForObject(PAYMENTURL + "deleteExpression", jsonObject,ResponseResult.class);
    }


}


